import { S } from '../s';
import { IPSLanguageRes } from './ipslanguage-res';
import { IPSSysUnit } from './ipssys-unit';
import { PSModelObjectImpl } from '../psmodel-object-impl';

export class PSSysUnitImpl extends PSModelObjectImpl implements IPSSysUnit {
  get codeName(): string {
    return this.M.codeName;
  }

  protected namepslanguageres: IPSLanguageRes;
  getNamePSLanguageRes(): IPSLanguageRes | null {
    return (
      this.namepslanguageres ||
      (this.namepslanguageres = this.fillObjectModel(
        S._276,
        this.M.getNamePSLanguageRes,
        S._2bd,
      ) as IPSLanguageRes)
    );
  }

  get unitTag(): string {
    return this.M.unitTag;
  }

  get unitTag2(): string {
    return this.M.unitTag2;
  }
  get cls(): string {
    return 'PSSysUnitImpl';
  }
  instanceof(cls: string): boolean {
    if (cls == S._27d) return true;
    return super.instanceof(cls);
  }
}
